import request from '@/utils/request'

// 查询生产入库管理列表
// export function listProductionEceipt(query) {
//   return request({
//     url: '/InboundManagement/productionEceipt/list',
//     method: 'get',
//     params: query
//   })
// }
// export function listProductionEceipt(query) {
//   return request({
//     url: '/OutboundManagement/deliveryOperation/list',
//     method: 'get',
//     params: query
//   })
// }
export function listProductionEceipt(query) {
  return request({
    url: '/OutboundManagement/deliveryOperation/findByZhijianList',
    method: 'get',
    params: query
  })
}
// 查询生产入库管理详细
export function getProductionEceipt(eceiptId) {
  return request({
    url: '/InboundManagement/productionEceipt/' + eceiptId,
    method: 'get'
  })
}

// 新增生产入库管理
// export function addProductionEceipt(data) {
//   return request({
//     url: '/InboundManagement/productionEceipt',
//     method: 'post',
//     data: data
//   })
// }
export function addProductionEceipt(data) {
  return request({
    url: '/OutboundManagement/deliveryOperation',
    method: 'post',
    data: data
  })
}
// // 修改入库检管理
// export function updateInboundInspection(data) {
//   return request({
//     url: '/OutboundManagement/deliveryOperation',
//     method: 'put',
//     data: data
//   })
// }
// 修改生产入库管理
// export function updateProductionEceipt(data) {
//   return request({
//     url: '/InboundManagement/productionEceipt',
//     method: 'put',
//     data: data
//   })
// }
export function updateProductionEceipt(data) {
  return request({
    url: '/OutboundManagement/deliveryOperation',
    method: 'put',
    data: data
  })
}
// 删除生产入库管理
// export function delProductionEceipt(eceiptId) {
//   return request({
//     url: '/InboundManagement/productionEceipt/' + eceiptId,
//     method: 'delete'
//   })
// }
export function delProductionEceipt(deliveryIds) {
  return request({
    url: '/OutboundManagement/deliveryOperation/' + deliveryIds,
    method: 'delete'
  })
}
